---
import type { FAQType } from '../../components/FAQs/FAQs.astro';

export const faqs: FAQType[] = [
  {
    question: 'What skills does a JavaScript developer need?',
    answer: [
      'A JavaScript developer needs to have a solid grasp of core JavaScript concepts to be successful because those will be the only common concepts that any framework or library they might depend on will use.',
      'These core concepts include functions, operators, and data structures. And they should include experience with at least one JavaScript framework or core library, such as React for building interactive websites or NextJS for backends.',
      "If their focus is back-end development, concepts such as API design and integration, data modeling, server-side rendering, and database querying are a must, as these will be part of the developer's daily tasks.",
      "Front-end developers should also learn about web standards, the DOM API, web components (or lightning web components if you're working with the Salesforce ecosystem), and have some basic understanding of UX.",
      'Candidates looking to prepare for [JavaScript developer interview questions](https://roadmap.sh/questions/javascript) should include the above-mentioned topics in their study program. For that, many developers schedule their studies at their own pace through extensive documentation, online training, and roadmaps like this one to build a solid foundational knowledge base.',
    ],
  },
  {
    question: 'Is JavaScript hard to learn?',
    answer: [
      "JavaScript can be challenging at first, but it's not necessarily hard to learn. It has a lot of flexibility, which can be both a strength and a source of confusion. If you're new to programming, it might feel overwhelming due to the variety of ways you can do the same thing.",
      'However, if you have some programming background, JS can be accessible due to its extensive online documentation and supportive community, which makes it easier to learn at your own pace.',
      "As learners progress and encounter the language's continuous stream of new features (due to its constant evolution), the learning process becomes challenging and rewarding. More here: [Is JavaScript hard to learn?](https://roadmap.sh/javascript/hard-to-learn)",
    ],
  },
  {
    question: 'How much is a JavaScript developer paid?',
    answer: [
      'JavaScript developers are usually paid very well due to their high demand. The web industry keeps growing, and the demand for developers who can build complex experiences is even higher. This translates to companies fighting each other over JavaScript developers, which tends to increase the base salary for these roles.',
      'That said, compensation can vary significantly based on factors such as geographical location and level of expertise. Salaries tend to be competitive in major tech hubs like New York and San Francisco, and experienced professionals or certified JavaScript developers with extensive knowledge of JavaScript frameworks often require higher pay.',
      "As a basis for comparison, according to sites such as Glassdoors, an average JavaScript developer earns 70,000 USD in the United States at an entry level (about 1 year of experience). Someone who's more experienced (10+ years of experience), however, can take that number to 110,000 USD on average.",
      "In the end, it depends on the company and how much they're willing to pay, as well as on your negotiation skills.",
    ],
  },
  {
    question: 'How is JavaScript different from Java?',
    answer: [
      'JavaScript is very different from Java, despite the similarity in their names. This is because JavaScript and Java are fundamentally different languages. JavaScript is a dynamically typed language that favors a mixed programming model between procedural and functional programming with some sprinkles of OOP, while Java is a statically typed, object-oriented language.',
      'JavaScript usually runs in browsers or server environments like Node.js, whereas Java is commonly used in desktop and server-side applications requiring the Java Virtual Machine (JVM) to be executed.',
      "These differences extend to the languages' design philosophies and learning curves, with JavaScript emphasizing dynamic content creation through flexible tools and data structures.",
    ],
  },
  {
    question: 'How is JavaScript different from PHP?',
    answer: [
      'JavaScript is very different from PHP because it serves a different role within the web development ecosystem.',
      'JavaScript can be used both by front-end developers to create interactive elements and on the back-end to code business logic, while PHP is a server-side-only scripting language that manages backend logic.',
      'Developers can use a combination of the two to build web applications that blend interactive design (thanks to JavaScript) with robust server-side functionality (thanks to PHP).',
    ],
  },
  {
    question: 'How is JavaScript different from TypeScript?',
    answer: [
      'JavaScript is different from TypeScript because TS is a superset of JavaScript. In other words, TypeScript enhances the language by adding new features that tend to align with the expectations of many developers (especially those coming from other languages like Java).',
      'Although TypeScript introduces additional layers of explicit documentation and data type definitions, it also builds on the core principles of JavaScript (so at its core, it feels like JavaScript and is compatible with it). At the end of the day, they can both be used to build interactive web applications.',
      'Many certified JavaScript developers and front end experts choose TypeScript for its ability to produce more robust and maintainable code while still relying on the flexible and innovative features that make JavaScript the de facto tool for web developers.',
    ],
  },
];
---
